Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

allow qute.html extension for templates #71

Merged
merged 1 commit into from
Jan 9, 2024
Merged

Conversation

kucharzyk
Copy link
Contributor

This PR will fix issue #70 and allow using qute.html extension for templates

@mkouba
Copy link
Contributor

mkouba commented Jan 5, 2024

Hi @kucharzyk and thanks for the PR!

Just to be clear - this PR merely fixed the problem with index pages, right? In other words, /pub/foo.qute.html -> /foo works just fine but /pub/index.qute.html -> / does not (and is fixed with this PR).

@mkouba
Copy link
Contributor

mkouba commented Jan 5, 2024

@kucharzyk
Copy link
Contributor Author

You have right.

The problem was only for index.qute.html
I thought it wasn’t working at all but when I stared fixing it I’ve realized it is only the case with index.qute.htm

I will update the docs later today

@kucharzyk
Copy link
Contributor Author

@mkouba I've mentioned that we can use index.qute.html in docs.

There is one more thing that could be fixed later.

Currently index.html is available under paths /, /index and /index.html
But index.qute.html it is available under /, /index' and '/index.qute.html

It's a bit inconsistent and I am not sure if it is intended behaviour.

@kucharzyk
Copy link
Contributor Author

@mkouba I've added additional fix so index.qute.html should be available as /, /index, /index.html and /index.qute.html

@mkouba
Copy link
Contributor

mkouba commented Jan 8, 2024

@mkouba I've mentioned that we can use index.qute.html in docs.

There is one more thing that could be fixed later.

Currently index.html is available under paths /, /index and /index.html But index.qute.html it is available under /, /index' and '/index.qute.html

It's a bit inconsistent and I am not sure if it is intended behaviour.

@kucharzyk Hm, I don't think it's inconsistent. The idea is that you either use the full template name (/index.qute.html) or the name without suffix (/index) so that an appropriate variant can be selected (based on the accept HTTP header).

But it seems that we don't have a test for this use case. We should definitely add one.

I'd like to merge the fix for the index page first. Would you care to revert the other fix?

@kucharzyk
Copy link
Contributor Author

Thank you for the feedback.
I will revert the other fix later today.

@mkouba
Copy link
Contributor

mkouba commented Jan 8, 2024

Thank you for the feedback. I will revert the other fix later today.

Thanks!

@kucharzyk
Copy link
Contributor Author

@mkouba Done. I've reverted second fix

@mkouba mkouba merged commit ba928a1 into quarkiverse:main Jan 9, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants